---
title: dub.analytics.clicks.topUrls
sidebarTitle: Top URLs
description: Retrieve the top URLs by number of clicks for a given short link.
---

import AnalyticsArguments from "/snippets/analytics-arguments.mdx";

<Note>
  Analytics endpoints require a [Pro plan](https://d.to/pro) subscription or
  higher.
</Note>

<AnalyticsArguments />

## Response

<ResponseField name="url" type="string" required>
  The destination URL
</ResponseField>

<ResponseField name="clicks" type="number" required>
  The number of clicks from this URL
</ResponseField>

<RequestExample>

```typescript
await dub.analytics.clicks.topUrls({
  key: "dummy",
  domain: "dub.sh",
  interval: "30d",
});
```

</RequestExample>

<ResponseExample>

```typescript
[
  { url: "https://dub.co/", clicks: 13 },
  { url: "https://dub.co/?qr=", clicks: 4 },
];
```

</ResponseExample>
